import 'package:flutter/material.dart';
import 'package:hayll_app_village_master/hayll/network/base.dart';
import 'package:hayll_app_village_master/hayll/village_manager/village_route.dart';

void main() => runApp(createApp());

Widget createApp() {

  AbsNetwork.setHost(AbsNetworkHostType.HTTPS, 'www.hayll.cn', null);

  return MaterialApp(
    title: '华安E邻里-物管',
    theme: ThemeData(
      primarySwatch: Colors.blue,
    ),
    home: VillageRoutes.buildPage('/login', null),
    onGenerateRoute: (RouteSettings settings) {
      return MaterialPageRoute<Object>(builder: (BuildContext context) {
        return VillageRoutes.buildPage(settings.name, settings.arguments);
      });
    },
  );
}
